package com.example.demo.service.impl;

import com.example.demo.entity.ArticleAndReport;
import com.example.demo.mapper.ArticleAndReportMapper;
import com.example.demo.service.IArticleAndReportService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 举报文章表 服务实现类
 * </p>
 *
 * @author Mr.sdy
 * @since 2024-06-12
 */
@Service
public class ArticleAndReportServiceImpl extends ServiceImpl<ArticleAndReportMapper, ArticleAndReport> implements IArticleAndReportService {

    @Autowired
    private ArticleAndReportMapper articleAndReportMapper;

    @Override
    public boolean addArticleAndReport(ArticleAndReport articleAndReport) {
        if(articleAndReportMapper.insertArticleAndReport(articleAndReport) > 0){
            return true;
        }
        return false;
    }
}
